[ToC] [Up] [Back] [Next] ... [Book Plug] The Information Commons
.................... Introduction to HTML

8.3 Anonymous FTP via URLs

Files can be referenced via FTP using the URL convention. The general form is:

ftp://internet.address.edu/file/path/file.txt
This form makes an anonymous FTP request for the indicated file from the indicated machine.

If you specify a directory instead of a file (by requesting a URL such as ftp://internet.address.edu/file/path/, most browsers will give you a list of the directory contents and allow you to select files, or other directories.

NOTE If a URL points to a directory it *must* end with the slash character. This tells the URL that the desired target is a directory (i.e. the directory path) and not a file (i.e. the file path).

You can access non-anonymous ftp resources by specifying, within the URL, both the username and password of the account you wish to access. ( NOTE -- This is not secure -- see the following warning). For example:

ftp://joe_bozo:bl123@internet.address.edu/path/file.gz
allows you to access files on machine internet.address.edu belonging to user joe_bozo (password bl123).
******** WARNING ********
What is wrong with the above? Well, if you had this line in a html document it would mean that everybody who accessed this document would know joe_bozo's password. This is very unsecure, and is to be discouraged!

Other Notes


[ToC] [Up] [Back] [Next] ... [Book Plug] .................... Introduction to HTML

© Ian Graham 1994-1995 Page Last Updated: 4 December 1995